package com.zxhhyj.music.ui

import androidx.compose.runtime.Composable
import androidx.compose.runtime.mutableStateListOf
import androidx.compose.runtime.saveable.rememberSaveable
import androidx.navigation3.runtime.entryProvider
import androidx.navigation3.ui.NavDisplay
import com.zxhhyj.music.Screen

@Composable
fun Main() {
    val backStack = rememberSaveable { mutableStateListOf<Screen>(Screen.Home) }
    NavDisplay(backStack, entryProvider = entryProvider {
        entry<Screen.Home> {
            Home(backStack)
        }
        entry<Screen.Source> {
            Source()
        }
    })
}